/*    */ package dm.jdbc.pool;
/*    */ 
/*    */ import java.util.Hashtable;
/*    */ import javax.naming.Context;
/*    */ import javax.naming.Name;
/*    */ import javax.naming.spi.ObjectFactory;
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ public class DmdbDataSourceFactory
/*    */   implements ObjectFactory
/*    */ {
/* 34 */   private DmdbDataSourceFactory_bs rDsFactory = null;
/*    */   
/*    */   DmdbDataSourceFactory(DmdbDataSourceFactory_bs dsf)
/*    */   {
/* 38 */     this.rDsFactory = dsf;
/*    */   }
/*    */   
/*    */   DmdbDataSourceFactory_bs getRealDsFactory() {
/* 42 */     return this.rDsFactory;
/*    */   }
/*    */   
/*    */ 
/*    */   public DmdbDataSourceFactory()
/*    */   {
/* 48 */     this.rDsFactory = new DmdbDataSourceFactory_bs();
/*    */   }
/*    */   
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */   public Object getObjectInstance(Object obj, Name name, Context ctx, Hashtable<?, ?> env)
/*    */     throws Exception
/*    */   {
/* 67 */     Object oRet = this.rDsFactory.getObjectInstance(obj, name, ctx, env);
/*    */     
/* 69 */     if (oRet == null) {
/* 70 */       return oRet;
/*    */     }
/* 72 */     if ((oRet instanceof DmdbDataSource_bs)) {
/* 73 */       return new DmdbDataSource((DmdbDataSource_bs)oRet);
/*    */     }
/* 75 */     if ((oRet instanceof DmdbConnectionPoolDataSource_bs)) {
/* 76 */       return new DmdbConnectionPoolDataSource(
/* 77 */         (DmdbConnectionPoolDataSource_bs)oRet);
/*    */     }
/* 79 */     if ((oRet instanceof DmdbConnectionCache_bs)) {
/* 80 */       return new DmdbConnectionCache((DmdbConnectionCache_bs)oRet);
/*    */     }
/* 82 */     return oRet;
/*    */   }
/*    */ }


/* Location:              D:\Program Files\DBMS_20150813\jdbc\Dm7JdbcDriver17.jar!\dm\jdbc\pool\DmdbDataSourceFactory.class
 * Java compiler version: 7 (51.0)
 * JD-Core Version:       0.7.1
 */